@echo off
chcp 65001
echo Starting Label Studio ML Backend service...

:: Activate conda environment
call conda activate labelstudio

:: Check and create ML Backend
if not exist "my_ml_backend" (
    echo Creating ML Backend...
    label-studio-ml init my_ml_backend
)

:: Install dependencies
cd my_ml_backend
pip install -r requirements.txt
cd ..

:: Start ML Backend service
echo Starting Label Studio ML Backend service...
cd my_ml_backend
python api.py

pause